package com.lhk.appframework.ui.activity;

import android.os.Bundle;
import android.view.View;
import android.widget.ImageView;
import butterknife.Bind;
import butterknife.ButterKnife;

import com.lhk.appframework.MyApplication;
import com.lhk.appframework.R;
import com.lhk.appframework.presenter.splash.PresenterSplash;
import com.lhk.appframework.presenter.splash.PresenterSplashUI;
import com.lhk.appframework.ui.BaseActivity;

public class SplashActivity extends BaseActivity implements PresenterSplashUI{
	
	@Bind(R.id.splashLogoUI) View splashLogoUI;
	@Bind(R.id.splashAdvertisementUI) View splashAdvertisementUI;
	
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		
		
		PresenterSplash presenterSplash = MyApplication.getInstance().getFactoryPresenter().createPresenterSplash(this, this);
		presenterSplash.work();
	}

	@Override
	public void setLayout() {
		setContentView(R.layout.activity_splash);
	}

	@Override
	public void finishUI() {
		finish();
	}

	@Override
	public void showLogoUI() {
		splashLogoUI.setVisibility(View.VISIBLE);
	}
}
